package com.map.mwing;

import javax.swing.Icon;
import javax.swing.JLabel;
import com.map.tool.InstancePool;
import com.map.tool.MapProcessor;

public class BigMapLabel extends JLabel 
{
    private static MapProcessor mapProcessor;// 图形处理器对象
    @Override
    public void setIcon(Icon icon)
    {
        if (mapProcessor == null) 
        {
        	// 尚未获得图形处理器对象
            if (InstancePool.getMapProcessor() != null) 
            {
            	// 如果图形处理器对象已经创建
                mapProcessor = InstancePool.getMapProcessor();// 获得图形处理器对象
            }
        } 
        super.setIcon(icon);
    }
}
